package com.lzy.cloud.order.constants;

import com.lzy.cloud.order.constants.CommonConstants.Biz;

/**
 * Description:订单业务状态的描述 Create by lc Date:Apr 12, 2017 Time:2:27:11 PM
 */

public enum OrderStatusDesEnum {

    /**
     * 户外装备订单状态
     */
    OUTDOOR_NO_PAY(Biz.OUTDOOR, 0, "待支付"),
    OUTDOOR_NO_GOODS(Biz.OUTDOOR, 1, "待发货"),
    OUTDOOR_YES_GOODS(Biz.OUTDOOR, 2, "待收货"),
    OUTDOOR_COMPLETE(Biz.OUTDOOR, 3, "已完结"),
    OUTDOOR_CAMP(Biz.OUTDOOR, 4, "已关闭"),
    OUTDOOR_PAYING(Biz.OUTDOOR, 5, "退款中"),
    OUTDOOR_PAYED(Biz.OUTDOOR, 6, "已退款"),
    /**
     * 房车销售订单状态
     */
    TOURCARSALE_NO_PAY(Biz.TOUR_CAR_SALE, 0, "待支付"),
    //支付保证金
    TOURCARSALE_YES_PAY(Biz.TOUR_CAR_SALE, 1, "待联系"),
    TOURCARSALE_NO_GOODS(Biz.TOUR_CAR_SALE, 3, "已完结"),
    TOURCARSALE_YES_GOODS(Biz.TOUR_CAR_SALE, 4, "已关闭"),
    /**
     * 房车租赁订单状态
     */
    TOURCARRENT_NO_PAY(Biz.TOUR_CAR_RENT, 0, "待支付"),
    TOURCARRENT_NO_GOODS(Biz.TOUR_CAR_RENT, 1, "待提车"),
    TOURCARRENT_YES_GOODS(Biz.TOUR_CAR_RENT, 2, "旅途中"),
    TOURCARRENT_COMPLETE(Biz.TOUR_CAR_RENT, 3, "已完结"),
    TOURCARRENT_CAMP(Biz.TOUR_CAR_RENT, 4, "已关闭 "),
    TOURCARRENT_PAYING(Biz.TOUR_CAR_RENT, 5, "退订中"),
    TOURCARRENT_PAYED(Biz.TOUR_CAR_RENT, 6, "已退款"),

    /**
     * 房车租赁车状态  1-未提车 2-已提车 3-未还车 4-已还车 5-已还车（用户点击）
     */
    TOURCARRENT_NO_STATE(Biz.TOUR_CAR_STATE, 0, "无"),
    TOURCARRENT_NOT_CAR(Biz.TOUR_CAR_STATE, 1, "未提车"),
    TOURCARRENT_PICK_CAR(Biz.TOUR_CAR_STATE, 2, "已提车"),
    TOURCARRENT_NO_CAR(Biz.TOUR_CAR_STATE, 3, "未还车"),
    TOURCARRENT_HAVE_CAR(Biz.TOUR_CAR_STATE, 4, "已还车"),
    TOURCARRENT_USERSHAVE_CAR(Biz.TOUR_CAR_STATE, 5, "已还车（用户点击）"),

    /**
     * 玩什么订单状态
     */
    PLAY_NO_PAY(Biz.PLAY, 0, "待支付"),
    PLAY_NO_GOODS(Biz.PLAY, 1, "待使用"),
    PLAY_COMPLETE(Biz.PLAY, 3, "已完结"),
    PLAY_CAMP(Biz.PLAY, 4, "已关闭 "),
    PLAY_PAYING(Biz.PLAY, 5, "退订中"),
    PLAY_PAYED(Biz.PLAY, 6, "已退款"),

    /**
     * 汽摩券订单状态
     */
    MOTOR_COUPON_NO_PAY(Biz.MOTOR_COUPON, 0, "待支付"),
    MOTOR_COUPON_COMPLETE(Biz.MOTOR_COUPON, 3, "已完结"),
    MOTOR_COUPON_CAMP(Biz.MOTOR_COUPON, 4, "已关闭 "),

    /**
     * 圆梦计划订单状态
     */
    DREAM_PLAN_NO_PAY(Biz.DREAM_PLAN, 0, "待支付"),
    DREAM_PLAN_COMPLETE(Biz.DREAM_PLAN, 3, "已完结"),
    DREAM_PLAN_CAMP(Biz.DREAM_PLAN, 4, "已关闭 "),

    /**
     * 代理商产品订单状态
     */
    AGENT_PRODUCT_NO_PAY(Biz.DREAM_PLAN, 0, "待支付"),
    AGENT_PRODUCT_COMPLETE(Biz.DREAM_PLAN, 3, "已完结"),
    AGENT_PRODUCT_CAMP(Biz.DREAM_PLAN, 4, "已关闭 "),

    /**
     * 女王节活动订单状态
     */
    QUEEN_PLAN_NO_PAY(Biz.QUEEN_PLAN, 0, "待支付"),
    QUEEN_PLAN_COMPLETE(Biz.QUEEN_PLAN, 3, "已完结"),
    QUEEN_PLAN_CAMP(Biz.QUEEN_PLAN, 4, "已关闭 "),

    /**
     * 智能设备（水电桩）订单状态
     */
    INTELLIGENT_DEVICE_NO_PAY(Biz.INTELLIGENT_DEVICE, 0, "待支付"),
    INTELLIGENT_DEVICE_NO_GOODS(Biz.INTELLIGENT_DEVICE, 1, "使用中"),
    INTELLIGENT_DEVICE_COMPLETE(Biz.INTELLIGENT_DEVICE, 3, "已完结"),
    INTELLIGENT_DEVICE_CAMP(Biz.INTELLIGENT_DEVICE, 4, "已关闭 "),
    INTELLIGENT_DEVICE_PAYING(Biz.INTELLIGENT_DEVICE, 5, "退订中"),
    INTELLIGENT_DEVICE_PAYED(Biz.INTELLIGENT_DEVICE, 6, "已退款"),

    /**
     * 一日游订单状态
     */
    GUIDE_NO_PAY(Biz.GUIDE, 0, "待支付"),
    GUIDE_NO_CONFIRM(Biz.GUIDE, 7, "待确认"),
    GUIDE_NO_GOODS(Biz.GUIDE, 1, "待使用"),
    GUIDE_YES_GOODS(Biz.GUIDE, 2, "出行中"),
    GUIDE_COMPLETE(Biz.GUIDE, 3, "已完结"),
    GUIDE_CAMP(Biz.GUIDE, 4, "已关闭 "),
    GUIDE_PAYING(Biz.GUIDE, 5, "退订中"),
    GUIDE_PAYED(Biz.GUIDE, 6, "已退款"),

    /**
     * 都在玩
     */
    PROMOTION_NO_PAY(Biz.PROMOTION, 0, "待支付"),
    PROMOTION_NO_GOODS(Biz.PROMOTION, 1, "待使用"),
    //	PROMOTION_YES_GOODS(Biz.PROMOTION, 	2, "出行中"),
    PROMOTION_COMPLETE(Biz.PROMOTION, 3, "已完结"),
    PROMOTION_CAMP(Biz.PROMOTION, 4, "已关闭 "),
    PROMOTION_PAYING(Biz.PROMOTION, 5, "退订中"),
    PROMOTION_PAYED(Biz.PROMOTION, 6, "已退款"),

    /**
     * 露营地订单状态
     */
    CAMPSITE_NO_PAY(Biz.CAMP, 0, "待支付"),
    CAMPSITE_NO_GOODS(Biz.CAMP, 1, "未出行"),
    CAMPSITE_YES_GOODS(Biz.CAMP, 2, "出行中"),
    CAMPSITE_COMPLETE(Biz.CAMP, 3, "已完结"),
    CAMPSITE_CAMP(Biz.CAMP, 4, "已关闭 "),
    CAMPSITE_PAYING(Biz.CAMP, 5, "退订中"),
    CAMPSITE_PAYED(Biz.CAMP, 6, "已退款"),
    /**
     * 房旅生活订单状态
     */
    JOURNEY_NO_PAY(Biz.CAMP, 0, "待支付"),
    JOURNEY_NO_GOODS(Biz.CAMP, 1, "未出行"),
    JOURNEY_YES_GOODS(Biz.CAMP, 2, "出行中"),
    JOURNEY_COMPLETE(Biz.CAMP, 3, "已完结"),
    JOURNEY_CAMP(Biz.CAMP, 4, "已关闭 "),
    JOURNEY_PAYING(Biz.CAMP, 5, "退订中"),
    JOURNEY_PAYED(Biz.CAMP, 6, "已退款");

    /**
     * @param type   业务类型
     * @param status 订单状态
     * @param des    描述
     */
    OrderStatusDesEnum(String type, Integer status, String des) {
        this.type = type;
        this.status = status;
        this.des = des;
    }

    /**
     * 获取des描述
     *
     * @param type
     * @param status
     * @return
     */
    public static String getByTypeAndStatus(String type, Integer status) {
        for (OrderStatusDesEnum c : OrderStatusDesEnum.values()) {
            if (c.getType().equals(type) && c.getStatus().equals(status)) {
                return c.getDes();
            }
        }
        return "";
    }

    // 业务类型
    private String type;
    // 订单状态
    private Integer status;
    // 描述
    private String des;

    public String getType() {
        return type;
    }

    public void setType(String type) {
        this.type = type;
    }

    public Integer getStatus() {
        return status;
    }

    public void setStatus(Integer status) {
        this.status = status;
    }

    public String getDes() {
        return des;
    }

    public void setDes(String des) {
        this.des = des;
    }
}
